package com.logic.modular.gameCore.pay.drawCards.controller;

import com.logic.modular.gameCore.pay.drawCards.service.impl.CoreDrawConfigServiceImpl;
import com.comment.pojo.domain.logic.core.CoreDrawConfig;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.AllArgsConstructor;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;

import com.comment.util.message.ResponseResult;

import java.util.List;


/**
 * 抽卡配置(按类型-稀有度)(CoreDrawConfig)表服务控制层
 *
 * @author cxy
 * @since 2024-08-08 16:38:25
 */
@Api(tags = "抽卡配置(按类型-稀有度)(CoreDrawConfig)") 
@Validated
@RestController
@AllArgsConstructor
@RequestMapping("/coreDrawConfig")
public class CoreDrawConfigController {
    @Resource
    private CoreDrawConfigServiceImpl coreDrawConfigService;
    
    @ApiOperation("获取抽卡配置(按类型-稀有度)列表")
    @PostMapping("/list")
    public ResponseResult<List<CoreDrawConfig>> list() {
        return ResponseResult.success(coreDrawConfigService.listCache());
    }
    // @GetMapping("/export")
    // public void Export(HttpServletResponse response) throws FileNotFoundException {
    //     coreDrawConfigService.export(response);
    // }
}
